Skip to content

Instantly share code, notes, and snippets.

@csharpforevermore
csharpforevermore / AuthoHotKeyList.txt
Created April 27, 2014 15:50
AutoHotKey Key List
Key Name Resulting Keystroke
{F1} - {F24} Function keys. For example: {F12} is the F12 key.
{!} !
{#} #
{+} +
{^} ^
{{} {
{}} }
{Enter} ENTER key on the main keyboard
{Escape} or {Esc} ESCAPE
@fzakaria
fzakaria / README.md
Created June 8, 2026 15:12
Cache-aware struct benchmarks: pointer-chasing staircase & AoS vs SoA

Cache-Aware Struct Benchmarks

Benchmarks demonstrating how struct size and memory layout affect performance due to CPU cache behavior. Companion code for the blog post Every byte matters.

Benchmarks

1. Pointer-Chasing (cache staircase)

LLM Wiki

A pattern for building personal knowledge bases using LLMs.

This is an idea file, it is designed to be copy pasted to your own LLM Agent (e.g. OpenAI Codex, Claude Code, OpenCode / Pi, or etc.). Its goal is to communicate the high level idea, but your agent will build out the specifics in collaboration with you.

The core idea

Most people's experience with LLMs and documents looks like RAG: you upload a collection of files, the LLM retrieves relevant chunks at query time, and generates an answer. This works, but the LLM is rediscovering knowledge from scratch on every question. There's no accumulation. Ask a subtle question that requires synthesizing five documents, and the LLM has to find and piece together the relevant fragments every time. Nothing is built up. NotebookLM, ChatGPT file uploads, and most RAG systems work this way.

@mauriciogior
mauriciogior / package.json
Last active June 15, 2026 20:26
Busca PlacasBrasil
{
"name": "placasbrasil-search",
"version": "1.0.0",
"description": "PlacasBrasil Search",
"main": "search.js",
"scripts": {
"search": "node search.js"
},
"dependencies": {
"cheerio": "^1.0.0",
@Belladone-Bzz
Belladone-Bzz / maze.py
Last active June 15, 2026 20:21
Utility file insertible into python projects that generate perfect or imperfect maze with different algorithms
from pydantic import BaseModel, Field, model_validator
from typing import Annotated
from collections.abc import Generator, Callable
from enum import IntEnum, Enum
from random import seed as set_seed, choice, randint, shuffle
MazeDimension = Annotated[int, Field(ge=3)]
CellCoordinates = Annotated[
@xcsrz
xcsrz / center_text_on_image.py
Created March 8, 2017 00:17
Center text on an image with Python and OpenCV. Had to come up with it myself as no one was spelling this out anywhere (or google couldn't find it)
#!/usr/bin/env python
import numpy as np
import cv2
from time import sleep
# create blank image - y, x
img = np.zeros((600, 1000, 3), np.uint8)
# setup text
@ResistanceIsUseless
ResistanceIsUseless / Header-Injection.yaml
Last active June 15, 2026 20:11
Nuclei SSRF Fuzzing Template
id: header-injection
info:
name: Header SSRF Injection
author: nullrabbit
severity: high
description: Fuzzing headers for OOB SSRF
tags: fuzz,ssrf
requests:
@astamicu
astamicu / Remove videos from Youtube Watch Later playlist.md
Last active June 15, 2026 20:07
Script to remove all videos from Youtube Watch Later playlist

UPDATED 22.11.2022

It's been two years since the last update, so here's the updated working script as per the comments below.

Thanks to BryanHaley for this.

setInterval(function () {
    video = document.getElementsByTagName('ytd-playlist-video-renderer')[0];

 video.querySelector('#primary button[aria-label="Action menu"]').click();
@oanhnn
oanhnn / using-multiple-github-accounts-with-ssh-keys.md
Last active June 15, 2026 20:06
Using multiple github accounts with ssh keys

Problem

I have two Github accounts: oanhnn (personal) and superman (for work). I want to use both accounts on same computer (without typing password everytime, when doing git push or pull).

Solution

Use ssh keys and define host aliases in ssh config file (each alias for an account).

How to?

  1. Generate ssh key pairs for accounts and add them to GitHub accounts.